Previous Book Contents Book Index Next

Inside Macintosh: QuickTime /
Chapter 2 - Movie Toolbox / Movie Toolbox Reference
Functions That Modify Movie Properties / Working with Movie Time


GetMovieDuration

The GetMovieDuration function returns the duration of a movie. The Movie Toolbox examines the durations of all the tracks of the movie to determine this value.

pascal TimeValue GetMovieDuration (Movie theMovie);
theMovie
Specifies the movie for this operation. Your application obtains this movie identifier from such functions as NewMovie, NewMovieFromFile, and NewMovieFromHandle (described on page 2-80, page 2-76, and page 2-78, respectively).
DESCRIPTION
The GetMovieDuration function returns a time value. This time value indicates the movie's duration, and it is expressed in the movie's time scale.

You cannot set movie direction explicitly because it is calculated as being the maximum durations of all the tracks in the movie.

ERROR CODES
invalidMovie-2010This movie is corrupted or invalid

Previous Book Contents Book Index Next

© Apple Computer, Inc.
6 JUL 1996